<!DOCTYPE html5>
<html>
    <head>
        {include file="public/header"}
    </head>
    <body>
        <div class="col-lg-10 col-sm-10">
            <div class="">
                <form id="search" class="form form-horizontal" action="search">
                    <div class="form-group">
                        <div class="col-lg-6 col-sm-6">
                            <input class="form-control" type="text" name="keyword" value="" placeholder="输入试卷名称查询">
                        </div>
                        <div class="col-lg-3 col-sm-3">
                            <button class="btn btn-primary" onclick="edu.create()"><span class="fa fa-plus"></span> 添加试卷</button>
                        </div>
                    </div>
                </form>
            </div>
        </div>

        </div>
	        <div class="col-lg-12" >
                <div id="arttb">
                    <table width="100%" class="table table-striped table-bordered table-hover">
                        <thead>
                            <tr>
                                <th>名称</th>
                                <th>备注</th>
                                <th>题目</th>
                                <th>操作</th>
                            </tr>
                        </thead>
                        <tbody>
                            {volist name="data" id="vo"}
                            <tr id="row-{$vo.pap_id}">
                                <td>{$vo.pap_name}</td>
                                <td>{$vo.pap_mark}</td>
                                <td>
                                    {php} if($vo['pap_type'] == 1){ {/php}
                                    <a href="/index.php/admin/choice/special.html?id={$vo.pap_id}" type="button" class="btn btn-primary btn-xs" target="_blank">添加试题</a>
                                    <a href="/index.php/admin/choice/choice.html?id={$vo.pap_id}" type="button" class="btn btn-success btn-xs"  target="_blank">查看试题</a>
                                    {php} }else{  {/php}
                                    <a href="/index.php/admin/essay/add?id={$vo.pap_id}" type="button" class="btn btn-default btn-xs">添加试题</a>
                                    <a href="/index.php/admin/essay/index.html?id={$vo.pap_id}" type="button" class="btn btn-info btn-xs">查看题目</a>
                                    {php} } {/php}
                                </td>
                                <td>
                                    <button data-id="{$vo.pap_id}" type="button" class="btn btn-success btn-xs" onclick="edu.edit(this)">编辑</button>
                                    <button type="button" class="btn btn-danger btn-xs"  onclick="edu.remove(this)" data-id="{$vo.pap_id}">删除</button>
                                </td>

                            </tr>
                            {/volist}
                        </tbody>
                    </table>
                    {$data}
                </div>
            {include file="public/modalbox"}
            {include file="public/board"}
            {include file="public/javascript"}
            {include file="public/jqueryform"}
            
            <script type="text/javascript" src="/admin/script/paper/index.js"></script>
    </body>
</html>
